﻿using System;
using System.ComponentModel;
using DevExpress.Xpo;
using DevExpress.Data.Filtering;
using DevExpress.ExpressApp;
using DevExpress.Persistent.Base;
using DevExpress.Persistent.BaseImpl;
using DevExpress.Persistent.Validation;
namespace Top.Module.Domain
{
    [DefaultClassOptions]
    public class TopPurchaseOrder : BaseObject
    {
        //begin
        public TopPurchaseOrder(Session session) : base(session)
        {}
        public override void AfterConstruction(){base.AfterConstruction();}

        private string _SupplierMemo;
        [Size(SizeAttribute.Unlimited)]
        public string SupplierMemo
        {
            get
            {
                return _SupplierMemo;
            }
            set
            {
                SetPropertyValue("SupplierMemo", ref _SupplierMemo, value);
            }
        }
        private string _FenxiaoId;
        [Size(SizeAttribute.Unlimited)]
        public string FenxiaoId
        {
            get
            {
                return _FenxiaoId;
            }
            set
            {
                SetPropertyValue("FenxiaoId", ref _FenxiaoId, value);
            }
        }
        private string _PayType;
        [Size(SizeAttribute.Unlimited)]
        public string PayType
        {
            get
            {
                return _PayType;
            }
            set
            {
                SetPropertyValue("PayType", ref _PayType, value);
            }
        }
        private string _TradeType;
        [Size(SizeAttribute.Unlimited)]
        public string TradeType
        {
            get
            {
                return _TradeType;
            }
            set
            {
                SetPropertyValue("TradeType", ref _TradeType, value);
            }
        }
        private string _DistributorFrom;
        [Size(SizeAttribute.Unlimited)]
        public string DistributorFrom
        {
            get
            {
                return _DistributorFrom;
            }
            set
            {
                SetPropertyValue("DistributorFrom", ref _DistributorFrom, value);
            }
        }
        private string _Id;
        [Size(SizeAttribute.Unlimited)]
        public string Id
        {
            get
            {
                return _Id;
            }
            set
            {
                SetPropertyValue("Id", ref _Id, value);
            }
        }
        private string _Status;
        [Size(SizeAttribute.Unlimited)]
        public string Status
        {
            get
            {
                return _Status;
            }
            set
            {
                SetPropertyValue("Status", ref _Status, value);
            }
        }
        private string _BuyerNick;
        [Size(SizeAttribute.Unlimited)]
        public string BuyerNick
        {
            get
            {
                return _BuyerNick;
            }
            set
            {
                SetPropertyValue("BuyerNick", ref _BuyerNick, value);
            }
        }
        private string _Memo;
        [Size(SizeAttribute.Unlimited)]
        public string Memo
        {
            get
            {
                return _Memo;
            }
            set
            {
                SetPropertyValue("Memo", ref _Memo, value);
            }
        }
        private string _TcOrderId;
        [Size(SizeAttribute.Unlimited)]
        public string TcOrderId
        {
            get
            {
                return _TcOrderId;
            }
            set
            {
                SetPropertyValue("TcOrderId", ref _TcOrderId, value);
            }
        }
        private TopReceiver _Receiver;
        public TopReceiver Receiver
        {
            get
            {
                return _Receiver;
            }
            set
            {
                SetPropertyValue("Receiver", ref _Receiver, value);
            }
        }
        private string _SupplierFrom;
        [Size(SizeAttribute.Unlimited)]
        public string SupplierFrom
        {
            get
            {
                return _SupplierFrom;
            }
            set
            {
                SetPropertyValue("SupplierFrom", ref _SupplierFrom, value);
            }
        }
        private string _SupplierUsername;
        [Size(SizeAttribute.Unlimited)]
        public string SupplierUsername
        {
            get
            {
                return _SupplierUsername;
            }
            set
            {
                SetPropertyValue("SupplierUsername", ref _SupplierUsername, value);
            }
        }
        private string _DistributorUsername;
        [Size(SizeAttribute.Unlimited)]
        public string DistributorUsername
        {
            get
            {
                return _DistributorUsername;
            }
            set
            {
                SetPropertyValue("DistributorUsername", ref _DistributorUsername, value);
            }
        }
        private DateTime _Created;
        public DateTime Created
        {
            get
            {
                return _Created;
            }
            set
            {
                SetPropertyValue("Created", ref _Created, value);
            }
        }
        private string _AlipayNo;
        [Size(SizeAttribute.Unlimited)]
        public string AlipayNo
        {
            get
            {
                return _AlipayNo;
            }
            set
            {
                SetPropertyValue("AlipayNo", ref _AlipayNo, value);
            }
        }
        private decimal _TotalFee;
        public decimal TotalFee
        {
            get
            {
                return _TotalFee;
            }
            set
            {
                SetPropertyValue("TotalFee", ref _TotalFee, value);
            }
        }
        private decimal _PostFee;
        public decimal PostFee
        {
            get
            {
                return _PostFee;
            }
            set
            {
                SetPropertyValue("PostFee", ref _PostFee, value);
            }
        }
        private decimal _DistributorPayment;
        public decimal DistributorPayment
        {
            get
            {
                return _DistributorPayment;
            }
            set
            {
                SetPropertyValue("DistributorPayment", ref _DistributorPayment, value);
            }
        }
        private string _SnapshotUrl;
        [Size(SizeAttribute.Unlimited)]
        public string SnapshotUrl
        {
            get
            {
                return _SnapshotUrl;
            }
            set
            {
                SetPropertyValue("SnapshotUrl", ref _SnapshotUrl, value);
            }
        }
        private DateTime _PayTime;
        public DateTime PayTime
        {
            get
            {
                return _PayTime;
            }
            set
            {
                SetPropertyValue("PayTime", ref _PayTime, value);
            }
        }
        private DateTime _ConsignTime;
        public DateTime ConsignTime
        {
            get
            {
                return _ConsignTime;
            }
            set
            {
                SetPropertyValue("ConsignTime", ref _ConsignTime, value);
            }
        }
        private DateTime _Modified;
        public DateTime Modified
        {
            get
            {
                return _Modified;
            }
            set
            {
                SetPropertyValue("Modified", ref _Modified, value);
            }
        }
        [Association("PurchaseOrderSubPurchaseOrders", typeof(TopSubPurchaseOrder))]
        public XPCollection SubPurchaseOrders
        {
            get
            {
                return GetCollection("SubPurchaseOrders");
            }
        }
        //end
    }
}
